<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>    
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<c:set var="contextPath" value="${pageContext.request.contextPath}" />
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>전자계산소 장애처리 접수</title>
</head>
<body>
	
	<form:form commandName="faultHandlingRegCmd">
		<input type="hidden" id="faultHandlingNo" name="faultHandlingNo" value="${faultHandling.faultHandlingNo}" />
		<dl>
			<dt>장애처리 수정</dt>
			<dd>
				접수자 : 
				<form:select path="receptionistNo">
					<c:forEach items="${workerList}" var="worker">
						<form:option value="${worker.workerNo}">${worker.name} (${worker.contactNumber})</form:option>						
					</c:forEach>
				</form:select>  
			</dd>  
			<dd>
				접수일자 : ${faultHandling.receiptDate}
			</dd>
			<dd>
				요청처리일자 : 
				<form:input path="processYear"/>년
				<form:input path="processMonth"/>월
				<form:input path="processDayOfMonth"/>일
			</dd>	
			<dd>
				요청처리 근무시간 : 
				<form:select path="dutyHoursNo">
					<c:forEach items="${dutyHoursList}" var="dutyHours">
						<form:option value="${dutyHours.dutyHoursNo}">${dutyHours.dutyHours}</form:option>						
					</c:forEach>
				</form:select>   
			</dd>
			<dd>
				구분 : 
				<form:select path="requestTypeNo">
					<c:forEach items="${requestTypeList}" var="requestType">
						<form:option value="${requestType.requestTypeNo}">${requestType.requestType}</form:option>						
					</c:forEach>
				</form:select>
			</dd>
			<dd>
				처리상태 : 
				<form:select path="processStatusNo">
					<c:forEach items="${processStatusList}" var="processStatus">
						<form:option value="${processStatus.processStatusNo}">${processStatus.processStatus}</form:option>						
					</c:forEach>
				</form:select>
			</dd>
		</dl>
		
		<dl>
			<dt>의뢰자</dt>
			<dd>
				이름 : <form:input path="requesterName" />
			</dd>
			<dd>
				연락처 : <form:input path="requesterContactNumber" />
			</dd>
			<dd>
				A/S 요청장소 : <form:input path="requestPlace" />
			</dd>
			<dd>
				의뢰자 소속 부서명 : <form:input path="department" />
			</dd>
		</dl>
		
		<dl>
			<dt>요청내용</dt>
			<dd>
				<form:textarea path="requestContent"/>
			</dd>
		</dl>
		
		<dl>
			<dt>확인증상 및 처리내용</dt>
			<dd>
				<form:textarea path="processingInformation"/>
			</dd>
		</dl>
		
		<dl>
			<dt>최초작업자</dt>
			<dd>
				<form:select path="firstWorkerNo">
					<c:forEach items="${workerList}" var="worker">
						<form:option value="${worker.workerNo}">${worker.name}(${worker.contactNumber})</form:option>		
					</c:forEach>
				</form:select>
			</dd>
		</dl>
		
		<input type="submit" value="확인" />
		<a href="${contextPath}">목록</a>
	</form:form>
	
</body> 
</html>